package com.browan.constellation;

import android.app.TabActivity;
import android.content.Intent;
import android.content.res.Resources;
import android.os.Bundle;
import android.widget.TabHost;

public class Constellation extends TabActivity
{

	@Override
	public void onCreate(Bundle savedInstanceState)
	{
		// 启动service

		super.onCreate(savedInstanceState);
		setContentView(R.layout.main);
		TabHost tabHost = getTabHost(); // The activity TabHost

		Resources res = getResources();

		tabHost.addTab(tabHost.newTabSpec("gridview").setIndicator("列表", res.getDrawable(R.drawable.ic_tab_contacts))
				.setContent(new Intent(this, GridViewConstellation.class)));

		tabHost.addTab(tabHost.newTabSpec("rss").setIndicator("资讯", res.getDrawable(R.drawable.ic_tab_playlists)).setContent(
				new Intent(this, RssConstellation.class)));

		tabHost.addTab(tabHost.newTabSpec("history").setIndicator("收藏", res.getDrawable(R.drawable.browser_history_tab))
				.setContent(new Intent(this, HistoryActivity.class)));
//		tabHost.setCurrentTab(0);
	}

	@Override
	protected void onDestroy()
	{
		// 停止service
		super.onDestroy();
	}
}